# Maintainer: Felix Yan <felixonmars@archlinux.org>

pkgname=kylin-nm
pkgver=3.0.2
pkgrel=2
pkgdesc="Kylin network monitor used in ubuntu-kylin operation system"
arch=('loong64' 'x86_64')
license=('GPL')
url="https://github.com/ukui/kylin-nm"
groups=('ukui')
depends=('gsettings-qt' 'kwindowsystem5' 'qt5-svg' 'qt5-x11extras')
makedepends=('qt5-tools')
source=("$pkgname-$pkgver.tar.gz::https://github.com/ukui/kylin-nm/archive/v$pkgver.tar.gz")
sha512sums=('798fa334f91920604e55da48d5dcd7cdfb891eab4cd7ece65ef5843655ffc3e801e57f861c2c522f76fd5731d4aa230caf3a807683ab2829bcfad61b2b67ed59')

prepare() {
  cd kylin-nm-$pkgver
  sed -i '/dpkg-buildflags/d' kylin-nm.pro
}

build() {
  cd kylin-nm-$pkgver
  qmake-qt5 PREFIX=/usr
  make
}

package() {
  cd kylin-nm-$pkgver
  make INSTALL_ROOT="$pkgdir" install
}
